//
//  WKSectionSelectedButton.m
//  XTXOneToOne
//
//  Created by Canny on 2018/11/21.
//  Copyright © 2018年 WK. All rights reserved.
//

#import "WKSectionSelectedButton.h"
@interface WKSectionSelectedButton ()

@property(nonatomic,strong)UILabel *lab;


@end
@implementation WKSectionSelectedButton
- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        [self createUI];
    }
    return self;
}

-(void)createUI{
    
    UILabel * lab = [[UILabel alloc]init];
    [self addSubview:lab];
    lab.backgroundColor=ThemeColor;
    lab.font=[UIFont boldSystemFontOfSize:15];
    [lab mas_makeConstraints:^(MASConstraintMaker *make) {
        make.bottom.equalTo(self);
        make.height.equalTo(@(3));
        make.left.equalTo(self.mas_left).offset(10);
        make.right.equalTo(self.mas_right).offset(-10);
    }];
    _lab = lab;
    
}

-(void)setSelectedHidden:(BOOL)isHidden{
    
    _lab.hidden = isHidden;
}

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
